import moment from "moment";
export default {
  methods: {
    formatDate(time) {
      return moment(time * 1).format("YYYY-MM-DD");
    },

    // 格式化cTimeFormat
    cTimeFormat(row, column, cellValue, index) {
      let time = moment(cellValue).format("YYYY-MM-DD");
      return time;
    },
    // 格式化bTimeFormat
    bTimeFormat(row, column, cellValue, index) {
      let time = moment(cellValue).format("YYYY-MM-DD");
      return time;
    },
     // 格式化online,是否在线
     onlineFormat(row, column, cellValue, index) {
      let text = cellValue ? "在线" : "离线";
      return text;
    },
  },
};
